@import "../../theme/global.module";
//旋转
.custom-icon-spin:before {
  display: inline-block;
  -webkit-animation: loadingCircle 1s infinite linear;
  animation: loadingCircle 1s infinite linear;
}

@keyframes loadingCircle {
  100% {
    transform: rotate(360deg);
  }
}

:global {
  // --兼容自定义icon的菜单操作--

  .#{$ant-prefix}-btn > .iconfont + span,
  .#{$ant-prefix}-btn > span + .iconfont {
    margin-left: 8px;
  }

  // icon样式控制
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-item .iconfont,
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-submenu > .#{$ant-prefix}-menu-submenu-title .iconfont,
    // group中的
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-item-group > .#{$ant-prefix}-menu-item-group-list > .#{$ant-prefix}-menu-item .iconfont,
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-item-group > .#{$ant-prefix}-menu-item-group-list > .#{$ant-prefix}-menu-submenu > .#{$ant-prefix}-menu-submenu-title .iconfont,
  {
    font-size: 16px;
    line-height: 40px;
    margin: 0;
  }

  // 正常的, 隐藏所有兄弟节点
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-item .iconfont + span,
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-submenu > .#{$ant-prefix}-menu-submenu-title .iconfont + span,
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-submenu > .#{$ant-prefix}-menu-submenu-title .iconfont + .#{$ant-prefix}-menu-submenu-arrow,
  // group中的
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-item-group > .#{$ant-prefix}-menu-item-group-list > .#{$ant-prefix}-menu-item .iconfont + span,
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-item-group > .#{$ant-prefix}-menu-item-group-list > .#{$ant-prefix}-menu-submenu > .#{$ant-prefix}-menu-submenu-title .iconfont + span,
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-item-group > .#{$ant-prefix}-menu-item-group-list > .#{$ant-prefix}-menu-submenu > .#{$ant-prefix}-menu-submenu-title .iconfont + .#{$ant-prefix}-menu-submenu-arrow,
  {
    display: none !important;
  }

  .#{$ant-prefix}-menu-inline-collapsed-tooltip {
    pointer-events: none;
  }

  .#{$ant-prefix}-menu-inline-collapsed-tooltip .iconfont {
    display: none;
  }

  // item样式调整
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-item,
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-item-group > .#{$ant-prefix}-menu-item-group-list > .#{$ant-prefix}-menu-item,
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-item-group > .#{$ant-prefix}-menu-item-group-list > .#{$ant-prefix}-menu-submenu > .#{$ant-prefix}-menu-submenu-title,
  .#{$ant-prefix}-menu-inline-collapsed > .#{$ant-prefix}-menu-submenu > .#{$ant-prefix}-menu-submenu-title{
    padding: 0 22px !important;
    text-align: center;

    &:after{
      display: none;
    }
  }
}
